import request from "../utils/request";

export function addModule(params) {
    return request({
        url: "/menu/addMenu",
        method: "post",
        params,
    });
}

/**
 *
 * @param {修改模块} params
 * @returns
 */
export function editModule(params) {
    return request({
        url: "/menu/updateMenu",
        method: "post",
        params,
    });
}

/**
 * 删除
 */
export function delModule(params) {
    return request({
        url: "/menu/delMenu",
        method: "post",
        params,
    });
}

/**
 * 查询模块列表
 */
export function getModuleData(params) {
    return request({
        url: "/menu/listNotAuthority",
        method: "post",
        params,
        headers: { showLoading: true },
    });
}